<template>
    <div>
        <Tabs value="infoType">
            <!-- 网站中当前使用的地区信息为iveiw提供的地区级联选择组件，以下功能为手动添加网站中的地区，暂时用不到，已经注释掉 -->
            <!-- <TabPane label="地区管理" name="area">
                <Row>
                    <Col span="8">
                        <DictionaryList :data="tree.area" infoAlert="网站中可以选择的省份" title="省" @on-current-change="show_city"></DictionaryList>
                    </Col>
                    <Col span="8">
                        <DictionaryList :data="province_current" infoAlert="网站中可以选择的城市" title="市" @on-current-change="show_district"></DictionaryList>
                    </Col>
                    <Col span="8">
                        <DictionaryList :data="city_current" infoAlert="对应城市包含的区县" title="区"></DictionaryList>
                    </Col>
                </Row>
            </TabPane> -->
            <TabPane label="信息类别" name="infoType">
                <Row>
                    <Col span="8">
                        <DictionaryList :data="tree.notice" infoAlert="首页显示的通知公告及子类别" title="通知公告"></DictionaryList>
                    </Col>
                    <Col span="8">
                        <DictionaryList :data="tree.news" infoAlert="首页显示的新闻资讯及子类别" title="新闻资讯"></DictionaryList>
                    </Col>
                    <Col span="8">
                        <DictionaryList :data="tree.laws" infoAlert="首页显示的政策法规及子类别" title="政策法规"></DictionaryList>
                    </Col>
                </Row>
            </TabPane>
            <!-- <TabPane label="需求与服务" name="RandS">
                <Row>
                    <Col span="12">
                        <DictionaryList :data="tree.service" infoAlert="系统所包含的服务类别，在下方添加" title="服务类别"></DictionaryList>
                    </Col>
                    <Col span="12">
                        <DictionaryList :data="tree.demand" infoAlert="系统所包含的需求类别，在下方添加" title="需求类别"></DictionaryList>
                    </Col>
                </Row>
            </TabPane> -->
            <TabPane label="材料文件类别" name="file_submit_type">
                <Row>
                    <Col span="12" offset="4">
                        <DictionaryList :data="tree.file_submit_type" infoAlert="发布服务时需要企业方提供的文件或者材料类别" title="材料文件类别"></DictionaryList>
                    </Col>
                </Row>
            </TabPane>
            <TabPane label="行业类别" name="industry_type">
                <Row>
                    <Col span="12">
                        <DictionaryList :data="tree.industry"  infoAlert="系统所包含的行业类别，在下方添加" @on-current-change="show_industry" title="行业"></DictionaryList>
                    </Col>
                    <Col span="12">
                        <DictionaryList :data="industry_current" infoAlert="左侧对应行业所包含的子行业" title="子行业"></DictionaryList>
                    </Col>
                </Row>
            </TabPane>
            <TabPane label="企业类别" name="company_type">
                <Row>
                    <Col span="12" offset="4">
                        <DictionaryList :data="tree.company_type" infoAlert="企业注册时可选择的企业类别" title="企业类别"></DictionaryList>
                    </Col>
                </Row>
            </TabPane>
            <TabPane label="服务机构" name="service_agency">
                <Row>
                    <Col span="12" offset="4">
                        <DictionaryList :data="tree.service_agency" infoAlert="服务机构注册时可选择的类别" title="服务机构类别"></DictionaryList>
                    </Col>
                </Row>
            </TabPane>
            <TabPane label="友情链接" name="friendly_link">
                <Row>
                    <Col span="12" offset="4">
                        <DictionaryList :data="tree.friendly_link" infoAlert="网站首页展示的友情链接" title="友情链接" :options="{show_url:true}"></DictionaryList>
                    </Col>
                </Row>
            </TabPane>
            <TabPane label="帮助类别" name="help">
                <Row>
                    <Col span="12" offset="4">
                        <DictionaryList :data="tree.help" infoAlert="帮助中心的类别" title="帮助类别" :options="{}"></DictionaryList>
                    </Col>
                </Row>
            </TabPane>
        </Tabs>
    </div>
</template>
<<script>
import DictionaryList from "./DictionaryList";
export default {
  data(){
      return{
          //province_current: {},
          //city_current: {},
          industry_current:{}
      }
  },
  components: {
      DictionaryList
  },
  computed:{
      tree() {
          return this.$store.state.app.dicTree;
      }
  },
  methods:{
    // show_city(currentRow,oldCurrentRow){
    //     this.province_current = currentRow;
    //     this.city_current = {};
    // },
    // show_district(currentRow,oldCurrentRow){
    //     this.city_current = currentRow;
    // },
    show_industry(currentRow,oldCurrentRow){
        this.industry_current = currentRow;
    }
  }
}
</script>
